<template>
  <div class="broadside_container">
    <div>
      <router-link to="/gwc">
        <img src="@/assets/images/gwc.png" alt="" />
        <span>去购<br />物车</span>
      </router-link>
    </div>
    <div class="service-div">
      <a href="#">
        <img src="@/assets/images/gt2.png" alt="" />
        <span>联系<br />客服</span>
      </a>
    </div>
    <div>
      <router-link to="/grzx">
        <img src="@/assets/images/grzx.png" alt="" />
        <span>个人<br />中心</span>
      </router-link>
    </div>
    <div class="hidden-div">
      <a href="#top">
        <img src="@/assets/images/gt4.png" alt="" />
        <span>返回<br />顶部</span>
      </a>
    </div>
    <p class="hidden-p">400-800-8200</p>
  </div>
</template>

<script>
export default {
  name: 'myBroad'
}
</script>

<style lang="less" scoped>
.broadside_container {
  top: 400px;
  right: 20px;
  z-index: 999;
  position: fixed;
  a {
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.5s ease;
  }
  img {
    width: 50%;
    height: 50%;
  }
  div {
    width: 50px;
    height: 50px;
    margin-bottom: 10px;
    background-color: #fff;
    border: 1px solid #dbdbdb;
  }
  span {
    color: #fff;
    display: none;
    font-size: 13px;
  }
  .hidden-div {
    display: none;
    margin-bottom: 0;
    .parcel {
      border: none;
      display: flex;
      align-items: center;
      justify-content: center;
      transition: all 0.5s ease;
      background-color: #f5f5f5;
    }
    .parcel:hover {
      cursor: pointer;
      background-color: #a10000;
    }
  }
  .hidden-div:hover .parcel span {
    display: block;
  }
  .hidden-div:hover .parcel img {
    display: none;
  }
  a:hover {
    background-color: #a10000;
    img {
      display: none;
    }
    span {
      display: block;
    }
  }
  .hidden-p {
    top: 67px;
    left: -155px;
    display: none;
    padding: 10px;
    font-size: 14px;
    position: absolute;
    transition: all 1s ease;
    background-color: #fff;
    border: 1px solid #a10000;
  }
  .hidden-p::after {
    top: 50%;
    right: -6px;
    content: '';
    margin-top: -6px;
    position: absolute;
    border-left: 6px solid #a10000;
    border-top: 6px solid transparent;
    border-bottom: 6px solid transparent;
  }
}
</style>
